Skip to content

Drop reach capabilities#26246

Open
odersky wants to merge 9 commits into
scala:mainfrom
dotty-staging:drop-reach
Open

Drop reach capabilities#26246
odersky wants to merge 9 commits into
scala:mainfrom
dotty-staging:drop-reach

Conversation

@odersky

@odersky odersky commented Jun 6, 2026

Copy link
Copy Markdown
Contributor

Based on #26193

  • Change or disable reach capability tests
  • Drop deprecated features of cap
  • Drop generation of reach capabilties
  • Drop types and infrastructure for reach capabilities

@odersky odersky requested a review from a team as a code owner June 6, 2026 14:30
@odersky odersky marked this pull request as draft June 6, 2026 14:30
@odersky odersky force-pushed the drop-reach branch 2 times, most recently from f970ca2 to 258fd39 Compare June 8, 2026 11:31
odersky added 5 commits June 8, 2026 15:22
If a test can be rewritten using capset variables, do that, otherwise move to
tests/disabled/reaches.
Disable withReachCaptures
For now, swallow the `*` and issue an error that reach capabilities are no longer supported.
 - Drop Reach class and reach operations in Capability
 - Deprecate `reachCapability` annotation
 - Drop deep parameter in mapCapability
 - Drop deferredReaches config setting
 - Drop references to reach capabilities in comments

Also: An added test case where reach capabilities were confusing before.
@odersky odersky requested a review from natsukagami June 8, 2026 13:26
@odersky odersky marked this pull request as ready for review June 8, 2026 13:26

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The two syntax.md files need to be changed, too.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And will this forever parse a reach and give an error? Or is there a plan in place to truly drop it?

@odersky

odersky commented Jun 8, 2026

Copy link
Copy Markdown
Contributor Author

At some point we'll drop the parse. Maybe in ~6 months.

odersky added 4 commits June 8, 2026 15:44
 - Drop `@reserve` annotation.
 - The used parameters are now precisely the capset parameters.

The idea is that we can obtain delayed usage by placing capset parameters later in a curried parameter sequence.
No other provisions are needed. This simplifies the logic and explanation and avoids corner cases where we need
something to be used but the previous logic did not recognize it as such.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants